#pragma once
#include "UIControl.h"
#include"UILabel.h"

BEGIN_NAMESPACE(ui_manager)
BEGIN_NAMESPACE(ui_controls)

class UITextbox;
typedef std::shared_ptr<UITextbox> UITextboxPtr; // Shared pointer to manage dynamic UITextbox objects

class UITextbox : public UIControl
{
	friend class UIManager;

	UILabel text;
	int c_x;
	int c_y;
	int index;
	bool c_draw;
	bool t_draw;
	bool enabled_;

	void Render(UIPoint parentPosistion);
	
protected:

public:
	UITextbox(void);
	~UITextbox(void);
	// Setters

	// Getters
	UILabel& GetLabel(){return text;}

	void HandleEvent(ui_events::UIEvent ui_event);
	void BoundBy(UIManager& manager, bool is_component);
};

END_NAMESPACE // ui controls
END_NAMESPACE // ui manager